package design_pattern.command.demo01;

/**
 * @version 1.0.0
 * Created by cyd on 2022-06-16 10:38:12
 * @ClassName : design_pattern.command.demo01.Invoker
 * @Description : 调用者（顾客），该类要求Command类来执行execute方法，但是不在乎如何执行
 */
public class Invoker {
    private Command command;

    public void setCommand(Command command) {
        this.command = command;
    }

    public void executeCommand(){
        command.execute();
    }
}
